<script setup>
import { ref } from "vue";
import Son from "@/components/Son.vue";
import { useCounterStore } from "@/stores/counter.js";

const counterStore = useCounterStore();

const onClick = () => {
  console.log(counterStore.count);
  console.log(counterStore.doubleCount);
};
</script>

<template>
  <div class="app">
    {{ counterStore.count }}
    <button @click="onClick">点击</button>
    <button @click="counterStore.increment">++</button>
  </div>
</template>

<style scoped lang="scss"></style>
